Skip to content

increase upper bounds of main zig executable to 9G #23638

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Jan200101
Copy link
Contributor

On Fedora 42 aarch64 memory usage peaked at 8736403456 bytes
@alexrp alexrp enabled auto-merge (rebase) April 22, 2025 03:41
@Jan200101
Copy link
Contributor Author

hmm, I'm actually not entirely sure if this is the best idea.
the build runner checks if max_rss is larger than the available system memory and fails if it is, bumping this limit to 9G would make it impossible to compile on anything else... maybe this is just something that I'll need to carry as a downstream patch.

@alexrp alexrp disabled auto-merge April 22, 2025 13:11
@Jan200101
Copy link
Contributor Author

Andrew Kelley| said:

users of `zig build` can pass this flag to ignore that check:
```
  --maxrss <bytes>             Limit memory usage (default is to use available memory)
```

so its probably fine to merge

@erikarvstedt
Copy link
Contributor

One could also make the argument to not merge this and set --maxrss on Fedora aarch64 instead.

@Jan200101
Copy link
Contributor Author

One could also make the argument to not merge this and set --maxrss on Fedora aarch64 instead.

andrew made the decision that it should be bumped, see the zulip link in the description.

its also been bumped in the past due to rising memory demands #21916
it might make more sense to add it to the CMakeLists since thats where the memory consumption is biggest and its already done for x86 mingw, but that is not for me to decide


I tried to understand the code and apparently the --maxrss flag is only useful for setting the max amount of memory the build runner considers usable (even if there isn't as much memory available) while the per-step max_rss is enforced regardless of the flag value.

So there is no alternative to this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants